//
//  NativeViewManager.h
//  Unity-iPhone
//
//  Created by Karl on 2017/3/27.
//
//

#import <Foundation/Foundation.h>

typedef NS_ENUM(NSInteger, ViewType) {
    ViewTypeHomepage,
    ViewTypeScanpage,
    ViewTypeCapturepage
};

@protocol NativeViewManagerDelegate <NSObject>

@optional

- (void)captureCompleted;

@end


@interface NativeViewManager : NSObject

@property (nonatomic,assign) BOOL showHomePop;
@property (nonatomic,strong) UIWindow *nativeWindow;

+ (instancetype)sharedManager;

-(void)addDelegate:(id<NativeViewManagerDelegate>) delegate;

-(void)removeDelegate:(id<NativeViewManagerDelegate>) delegate;

- (void)view:(ViewType)view show:(BOOL)show;

- (void)targetSceneLoadCompleted:(NSString *)scene;

- (void)showWebWithURL:(NSString *)url inApp:(BOOL)inApp;

- (void)showWebWithURL:(NSString *)url;

- (void)shareImage:(UIImage *)image;

- (void)captureCompleted;

- (UIImage *)captureWithFrame;

@end
